package com.nix.web.databases.pojo.word;

import com.nix.web.databases.pojo.BasePojo;
import com.nix.web.databases.pojo.user.User;

import java.util.List;

/**
 * @author zhangpei
 * @Email zhangpe0312@qq.com
 * @day 2017/11/1 23:24
 * @Use 单词基础信息
 * name 单词名字
 * pinYin 单词的拼音
 * wordMeaning 词的解释
 */
public class Word extends BasePojo {
    private String name;
    private String pinYin;
    private String wordMeaning;
    private Integer frequency;

    /**
     * 一个单词一个词性
     * 一个单词多个标注
     * 一个单词有多个用户拥有
     * 一个单词可能由多个错误
     */
    private List<BasePojo> emtions;
    private Category category;
    private List<User> users;
    private List<WordError> wordErrors;


    public Word() {
    }


    public Word(String name, String pinYin, String wordMeaning, Integer frequency) {
        this.name = name;
        this.pinYin = pinYin;
        this.wordMeaning = wordMeaning;
        this.frequency = frequency;
    }

    public Integer getFrequency() {
        return frequency;
    }

    public void setFrequency(Integer frequency) {
        this.frequency = frequency;
    }

    public List<WordError> getWordErrors() {
        return wordErrors;
    }

    public void setWordErrors(List<WordError> wordErrors) {
        this.wordErrors = wordErrors;
    }

    public List<User> getUsers() {
        return users;
    }

    public void setUsers(List<User> users) {
        this.users = users;
    }

    public List<BasePojo> getEmtions() {
        return emtions;
    }

    public void setEmtions(List<BasePojo> emtions) {
        this.emtions = emtions;
    }

    public Category getCategory() {
        return category;
    }

    public void setCategory(Category category) {
        this.category = category;
    }

    public String getWordMeaning() {
        return wordMeaning;
    }

    public void setWordMeaning(String wordMeaning) {
        this.wordMeaning = wordMeaning;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPinYin() {
        return pinYin;
    }

    public void setPinYin(String pinYin) {
        this.pinYin = pinYin;
    }

    @Override
    public String toString() {
        return "Word{" +
                "name='" + name + '\'' +
                ", pinYin='" + pinYin + '\'' +
                ", wordMeaning='" + wordMeaning + '\'' +
                ", emtions=" + emtions +
                ", category=" + category +
                ", users=" + users +
                ", wordErrors=" + wordErrors +
                '}';
    }
}
